package com.ap.core.bulkupload.listener;

import com.ap.core.bulkupload.jaxb.domain.DistributorIdType;
import com.ap.core.bulkupload.jaxb.domain.FileHdrType;
import com.ap.core.bulkupload.jaxb.domain.Merchant;
import com.ap.core.bulkupload.jaxb.domain.Trailer;

/**
 * The listener interface for receiving parser events.
 * The class that is interested in processing a parser
 * event implements this interface, and the object created
 * with that class is registered with a component using the
 * component's <code>addParserListener<code> method. When
 * the parser event occurs, that object's appropriate
 * method is invoked.
 *
 * @see ParserEvent
 */
public interface ParserListener {
	/**
	 * On file header.
	 */
	void onFileHeader(FileHdrType fileType);
	
	/**
	 * On distributor.
	 */
	void onDistributor(DistributorIdType distributorId);
	
	/**
	 * On merchant.
	 *
	 * @param merchant the merchant
	 */
	void onMerchant(Merchant merchant);
	
	/**
	 * On trailer.
	 */
	void onTrailer(Trailer trailer);
}
